# -*- coding: utf-8 -*-

#   The following payoff matrix defines the possible outcomes for a hunt and it is clear that the Slack strategy has both better worst and best outcomes.
#   The only possible way to better the slack strategy is to consistently collaborate with one or more players.
#   I assumed that there could be multiple instances of the same player within a game and tried to devise a way for those players to recognise each other.
#       ╔═══════╦═══════╦════════════╦═══════════╗
#       ║   H   ║   S   ║ worst case ║ best case ║
# ╔═════╬═══════╬═══════╬════════════╬═══════════╣
# ║   h ║  0, 0 ║ -3, 1 ║     -3     ║     0     ║
# ╠═════╬═══════╬═══════╬════════════╬═══════════╣
# ║   s ║  1,-3 ║ -2,-2 ║     -2     ║     1     ║
# ╚═════╩═══════╩═══════╩════════════╩═══════════╝
  

class Player:
    def hunt_choices(self, round_number, current_food, current_reputation, m, player_reputations):
        decisions = []
        hunted = False
        for player_reputation in player_reputations:
            decision = 's'
            if (not hunted and current_reputation == 0) or (current_reputation > 0 and player_reputation == current_reputation):
                decision = 'h'
                hunted = True

            decisions.append(decision)

        return decisions

    def hunt_outcomes(self, food_earnings):
        pass

    def round_end(self, award, m, number_hunters):
        pass